

function modify(audit) {  
	//创建订单信息
	var orderId = $("span[id='orderId']").text();
	var refundsReason=$("textarea[name='info']").val();
	var shortToken=$("input[name='shortToken']").val();
  $.ajax({
    cache : true,
    type : "POST",
    url : ctx + "module/order/refundOrders",
    data :{ 
    	   'orderId':orderId,
    	   'refundsReason':refundsReason,
    	   'shortToken':shortToken,
    	   'audit':audit
    },
    async : false,
    error : function(request) {
      $.modalAlert("系统错误", "error");
    },
    success : function(data) {
      if (data.msg == 1) {
        parent.layer.msg("发起退单成功,正在刷新数据请稍后……",{icon:1,time: 500,shade: [0.1,'#fff']},function(){
          $.parentReload();
        });
      }else if(data.msg == -2){
    	//图片缓存已过期
		$.modalAlert("图片缓存已过期,请重试", "error");
      }else if(data.msg == -3) {
		//缓存数据异常
		$.modalAlert("缓存数据异常,请重试", "error");
	  }else if(data.msg == -4) {
		//操作异常
		$.modalAlert("未知异常,请重试", "error");
	  }else{
        $.modalAlert("未知异常", "error");
      }
    }
  });
}
